#ifndef _CABECERAS_
#define _CABECERAS_
#include <stdio.h>
#include <stdlib.h>
#include <string.h>

#define TRUE 1
#define FALSE 0

struct tProducto {
	int id;
	char nombre[30];
	unsigned int precio;
};

struct tOferta {
	int id;
	unsigned int num; // Número mínimo de weas que tiene que comprar pal descuento
	unsigned int descuento;
};

struct tCliente {
	int id;
	unsigned int cant;
};

unsigned int HT(int key, unsigned int max_tam); 
int hashinsert_P(unsigned int pos, struct tProducto [], unsigned int tam, struct tProducto);
int hashinsert_O(unsigned int pos, struct tOferta [], unsigned int tam, struct tOferta);
struct tProducto hashsearch_P(unsigned int pos, struct tProducto [],\
		unsigned int tam, unsigned int id);
struct tOferta hashsearch_O(unsigned int pos, struct tOferta [], \
		unsigned int tam, unsigned int id);
void liberar_memoria(char **strs, int lineas);
void reemplazar_caracter(char *str, int tam, char c, char r);
#endif
